<!-- @author zhengjie -->
<template>
  <div class="input-body">
    <el-input-number v-model="nums" :precision="2" :min="0">
    </el-input-number>
    <span style="margin-left:10px">%</span>

  </div>
</template>
  
<script>
export default {
  name: 'percentage',
  props: ["num"],
  computed: {
    nums: {
      get(val){
        return this.num
      },
      set(val){
        this.$emit('update:num', val)
      }
    }
  },
  methods: {
    // change(currentValue, oldValue) {
    //   this.nums = currentValue
    //   this.$emit('update:num', currentValue)
    // }
  }
}
</script>
  
<style rel="stylesheet/scss" lang="scss" scoped>
.input-body {
  width: 100%;
  padding: 10px;

  .input-list {
    height: 200px;
    overflow-y: scroll;

    div {
      height: 30px;
      line-height: 30px;
      margin-bottom: -5px;
      cursor: pointer;
      width: 33%;
      float: left;
    }

    span {
      display: inline-block;
      vertical-align: -0.15em;
      fill: currentColor;
      overflow: hidden;
    }
  }
}
</style>
  